package com.wuzhiming.istudy.service;

import com.wuzhiming.istudy.pojo.Collection;
import com.wuzhiming.istudy.pojo.Comment;

import java.util.List;

/**
 * @ClassName: CommentService
 * @Description:
 * @Author:zhimingw
 * @Version 1.0
 * @since 2022/3/16 19:56
 */
public interface CommentService {
    
    /**
    * @Description: 添加一个课程收藏
    * @Param: [collection]
    * @return: boolean
    * @Author: zhimingw
    * @Date: 2022/3/16
    */
    boolean addComment(Comment comment);

    /**
    * @Description: 获得某个课程下所有评论
    * @Param: [courseId]
    * @return: java.util.List<com.wuzhiming.istudy.pojo.Comment>
    * @Author: zhimingw
    * @Date: 2022/3/24
    */
    List<Comment> queryCommentById(Integer courseId);

    /**
    * @Description: 获取某个用户的所有评论
    * @Param: [comment]
    * @return: java.util.List<com.wuzhiming.istudy.pojo.Comment>
    * @Author: zhimingw
    * @Date: 2022/3/28
    */
    List<Comment> getUserComment(Comment comment);

    /**
     * @Description: 获取评论的数量
     * @Param: []
     * @return: java.lang.Integer
     * @Author: zhimingw
     * @Date: 2021/7/5
     */
    Integer getCount(Integer status);

    /**
     * @Description: 获取所有评论
     * @Param: [comment]
     * @return: java.util.List<com.wuzhiming.istudy.pojo.Comment>
     * @Author: zhimingw
     * @Date: 2022/3/28
     */
    List<Comment> queryAll();

    /**
    * @Description: 修改评论状态
    * @Param: [comment]
    * @return: boolean
    * @Author: zhimingw
    * @Date: 2022/3/31
    */
    boolean update(Comment comment);
}
